<?php
// error_reporting(E_ALL);
header("Content-type:text/html;charset=utf-8");
date_default_timezone_set('PRC');//北京时间
/* MySQL Setting */
define('DB_NAME',     'cms');/* 你的数据库名称*/
define('DB_USER',     'root');/* 你的数据库的用户名*/
define('DB_PASSWORD', 'root');/*你的数据库的密码*/
define('DB_HOST',     'localhost');/*你数据库的地址：一般默认*/
define('NSO_ADMIN_DIR_NAME',  'admin'); // 后台登陆地址
define('NSO_UPLOAD_DIR_NAME', 'uploads'); // SWFUpload上传文件夹
// ------------------------------------------------------------
// ------------------------------------------------------------
// WARNING!! CONFIG SETTING!! DOT'S MODIFY THE CODE BELOW!!
// ------------------------------------------------------------
// ------------------------------------------------------------
define("ROOT",str_replace("\\","/",dirname(__FILE__)).'/');//主绝对路径
define('WEB_PATH','thousand/',true);
define('NSO_ABSPATH', dirname(__FILE__) . '/');
define('NSO_LIBS_PATH', NSO_ABSPATH . 'libs/');
define('NSO_INC_PATH', NSO_ABSPATH . 'inc/');
define('NSO_UPLOAD_PATH', NSO_ABSPATH . NSO_UPLOAD_DIR_NAME . '/');
//定义文件上传的文件夹
define('WEB_UPLOAD_FILE','uploads');

$file_base_path=WEB_PATH.WEB_UPLOAD_FILE."/";

$pdo=new PDO('mysql:host='.DB_HOST.';dbname='.DB_NAME,DB_USER,DB_PASSWORD);
$pdo->exec('set names utf8');
$pdo->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE,PDO::FETCH_ASSOC);
// ------------------------------------------------------------
// SYSTEM SETTINGS
// ------------------------------------------------------------
require_once NSO_INC_PATH . 'NutFunction.php';
?>